<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" %>
<html>
<head>
    <jsp:include page="/static/common/common.jsp"/>
    <!--department js代码-->
    <script src="/static/js/department.js"></script>
    <title>员工管理</title>
</head>
<body>
<%--数据表格--%>
<table id="dept_datagrid">
</table>

<%--dept_toolbar工具框--%>
<div id="dept_toolbar">
    <a class="easyui-linkbutton" iconCls="icon-add" plain="true"
       data-cmd="add">新增</a>
    <a class="easyui-linkbutton" iconCls="icon-edit" plain="true"
       data-cmd="edit">编辑</a>
    <a id="state_btn" class="easyui-linkbutton" iconCls="icon-remove" plain="true"
       data-cmd="changeState">启用</a>
</div>

<%--弹出框--%>
<div id="dept_dialog" align="center">
    <form id="dept_form" method="post">
        <input type="hidden" name="id" id="deptId">
        <table align="center" style="margin-top: 15px">
            <tbody>
            <tr>
                <td>部门编号:</td>
                <td><input name="sn" class="easyui-textbox"
                           prompt="请输入部门编号"
                           invalidMessage="部门编号已存在"
                           validType="remote['/department/validateName.do?id='+deptId.value,'sn']">
                </td>
            </tr>
            <tr>
                <td>部门名称:</td>
                <td><input name="name" class="easyui-textbox"
                           prompt="请输入部门名称"></td>
            </tr>
            <tr>
                <td>部门状态:</td>
                <td><input name="state" class="easyui-combobox"
                           data-options="panelHeight:'auto', valueField:'value',textField:'text',
                        data:[{text:'启用',value:'1'},{text:'禁用',value:'0'}]"></td>
            </tr>
            </tbody>
        </table>
    </form>
</div>
</body>
</html>
